import request from '@/utils/request'

// 获取全部权限点
export const getPermissionAPI = () => request({
  url: '/sys/permission',
  method: 'get'
})
// 添加权限点
export const addPermissionAPI = data => request({
  url: '/sys/permission',
  method: 'post',
  data
})
// 删除权限点
export const delPermissionAPI = id => request({
  url: '/sys/permission/' + id,
  method: 'delete'
})
// 获取指定权限点数据
export const getIdPermissionAPI = id => request({
  url: '/sys/permission/' + id,
  method: 'get'
})
// 编辑权限点
export const editPermissionAPI = data => request({
  url: '/sys/permission/' + data.id,
  method: 'put',
  data
})
